package imu.g3.util;

import imu.g3.model.LoginLogInfo;
import imu.g3.model.User;
import imu.g3.service.SystemLogService;
import imu.g3.service.UserService;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class test {


    public static void main(String[] args) {
        ClassPathXmlApplicationContext xmlApplicationContext = new ClassPathXmlApplicationContext("classpath:WEB-INF/applicationContext.xml");
        SystemLogService service = (SystemLogService) xmlApplicationContext.getBean("systemLogService");
        LoginLogInfo log = new LoginLogInfo();
        log.setLoginTime("123");
        log.setUsername("aaa");
        //service.addLoginLog(log);




        UserService userService = (UserService) xmlApplicationContext.getBean("userService");
        User user = new User();
        user.setRegDate("123213");
        userService.register(user);


    }
}
